<template>
  <zyInfoPanel title="邀请员工" :showUnfoldButton="false" class="personnelInvite">
    <div class="qrcode">
      <zy-image readonly v-model="qrcode" class="img"></zy-image>
      <div class="text">扫描二维码</div>
      <div class="text1">企业将二维码发放给员工</div>
    </div>
  </zyInfoPanel>
</template>

<script>
	export default {
		name: "SPersonnelInvite",
		props: {},
		data() {
			return {
				qrcode: ''
      };
		},
		computed: {},
		watch: {},
		components: {},
		methods: {
			getData(){
				this.$axios.post(this.$api.userInfo, {}).then(res => {
					let {code, msg, data} = res;
					if (code == 200) {
						this.qrcode = data.qrcode;
					} else {
						this.$message.error(msg);
					}
				}).catch(ret => {
					this.$message.error(ret.msg || "服务繁忙，请稍后再试");
				});
      }
    },
		mounted() {
			this.getData()
		},
		created() {
		}
	}
</script>

<style scoped lang="less" src="@/style/sorting/personnel/personnelInvite/index.less">

</style>
